  /**
   * Generate time : 2012-12-13 7:11:30
   * Version : 1.0.1.V20070717
   */
package com.baosight.sczx.zm.domain;

import java.math.BigDecimal;
import com.baosight.iplat4j.util.NumberUtils;
import com.baosight.iplat4j.core.ei.EiColumn;
import com.baosight.iplat4j.ep.DaoEPBase;
import java.util.HashMap;
import java.util.Map;
import com.baosight.iplat4j.util.StringUtils;
/**
 * ZM99 
 *  
 */
public class ZM9V extends DaoEPBase {
	
	private String fdMaterialName = " ";		/* 物资名称*/
	private String fdSpecModel = " ";		/* 规格型号*/
	private String fdNumber = " ";		/* 图号*/
	private String fdQuality = " ";		/* 材质*/
	private BigDecimal fdNum = new BigDecimal("0");		/* 库存数量*/
	private BigDecimal fdExportNum = new BigDecimal("0");		/* 出库数量*/
	private BigDecimal fdImportNum = new BigDecimal("0");		/* 入库数量*/
	private BigDecimal fdPrice = new BigDecimal("0");		/* 单价*/
	private String fdMaterialCode = " ";		/* 物资编码*/

	/**
	 * initialize the metadata 
	 */
	public void initMetaData() {
		EiColumn eiColumn;
	
	eiColumn = new EiColumn("fdMaterialCode");
	eiColumn.setFieldLength(40);	
	eiColumn.setDescName("物资编码");
	eiMetadata.addMeta(eiColumn);

	
	eiColumn = new EiColumn("fdMaterialName");
	eiColumn.setFieldLength(80);	
	eiColumn.setDescName("物资名称");
	eiMetadata.addMeta(eiColumn);

	
	eiColumn = new EiColumn("fdSpecModel");
	eiColumn.setFieldLength(100);	
	eiColumn.setDescName("规格型号");
	eiMetadata.addMeta(eiColumn);
	
	eiColumn = new EiColumn("fdNumber");
	eiColumn.setFieldLength(100);	
	eiColumn.setDescName("图号");
	eiMetadata.addMeta(eiColumn);

	
	eiColumn = new EiColumn("fdNum");
	eiColumn.setType("N");
	eiColumn.setScaleLength(2);
	eiColumn.setFieldLength(20);
	eiColumn.setDescName("库存数量");
	eiMetadata.addMeta(eiColumn);
	
	eiColumn = new EiColumn("fdExportNum");
	eiColumn.setType("N");
	eiColumn.setScaleLength(10);
	eiColumn.setFieldLength(20);
	eiColumn.setDescName("出库数量");
	eiMetadata.addMeta(eiColumn);
	
	eiColumn = new EiColumn("fdImportNum");
	eiColumn.setType("N");
	eiColumn.setScaleLength(10);
	eiColumn.setFieldLength(20);
	eiColumn.setDescName("入库数量");
	eiMetadata.addMeta(eiColumn);
	
	eiColumn = new EiColumn("fdPrice");
	eiColumn.setType("N");
	eiColumn.setScaleLength(10);
	eiColumn.setFieldLength(20);
	eiColumn.setDescName("单价");
	eiMetadata.addMeta(eiColumn);
	

	}
	/**
	 * the constructor
	 */
	public ZM9V() {
		initMetaData();
	}
	
	
	
	/**
	 * get the fdMaterialCode - 物资编码
	 * @return the fdMaterialCode
	 */
	public String getFdMaterialCode() {
		return this.fdMaterialCode;
	}
	
	/**
	 * set the fdMaterialCode - 物资编码
	 */
	public void setFdMaterialCode(String fdMaterialCode) {
		this.fdMaterialCode = fdMaterialCode;
	}

	
	/**
	 * get the fdMaterialName - 物资名称
	 * @return the fdMaterialName
	 */
	public String getFdMaterialName() {
		return this.fdMaterialName;
	}
	
	/**
	 * set the fdMaterialName - 物资名称
	 */
	public void setFdMaterialName(String fdMaterialName) {
		this.fdMaterialName = fdMaterialName;
	}
	
	/**
	 * get the fdSpecModel - 规格型号
	 * @return the fdSpecModel
	 */
	public String getFdSpecModel() {
		return this.fdSpecModel;
	}
	
	/**
	 * set the fdSpecModel - 规格型号
	 */
	public void setFdSpecModel(String fdSpecModel) {
		this.fdSpecModel = fdSpecModel;
	}
	
	/**
	 * get the fdNumber - 图号
	 * @return the fdNumber
	 */
	public String getFdNumber() {
		return this.fdNumber;
	}
	
	/**
	 * set the fdNumber - 图号
	 */
	public void setFdNumber(String fdNumber) {
		this.fdNumber = fdNumber;
	}
	
	
	
	/**
	 * get the fdNum - 数量
	 * @return the fdNum
	 */
	public BigDecimal getFdNum() {
		return this.fdNum;
	}
	
	/**
	 * set the fdNum - 数量
	 */
	public void setFdNum(BigDecimal fdNum) {
		this.fdNum = fdNum;
	}
	
	/**
	 * get the fdExportNum - 出库数量
	 * @return the fdExportNum
	 */
	public BigDecimal getFdExportNum() {
		return this.fdExportNum;
	}
	
	/**
	 * set the fdExportNum - 出库数量
	 */
	public void setFdExportNum(BigDecimal fdExportNum) {
		this.fdExportNum = fdExportNum;
	}
	
	/**
	 * get the fdImportNum - 入库库数量
	 * @return the fdImportNum
	 */
	public BigDecimal getFdImportNum() {
		return this.fdImportNum;
	}
	
	/**
	 * set the fdImportNum - 入库库数量
	 */
	public void setFdfdImportNum(BigDecimal fdImportNum) {
		this.fdImportNum = fdImportNum;
	}
	
	/**
	 * get the fdPrice - 单价
	 * @return the fdPrice
	 */
	public BigDecimal getFdPrice() {
		return this.fdPrice;
	}
	
	/**
	 * set the fdPrice - 单价
	 */
	public void setFdPrice(BigDecimal fdPrice) {
		this.fdPrice = fdPrice;
	}
	
	/**
	 * get the value from Map
	 */
	public void fromMap(Map map) {
	
		setFdMaterialCode(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdMaterialCode")), fdMaterialCode));
		setFdMaterialName(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdMaterialName")), fdMaterialName));
		setFdSpecModel(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdSpecModel")), fdSpecModel));
		setFdNumber(StringUtils.defaultIfEmpty(StringUtils.toString(map.get("fdNumber")), fdNumber));
		setFdNum(NumberUtils.toBigDecimal(StringUtils.toString(map.get("fdNum")), fdNum));
		setFdExportNum(NumberUtils.toBigDecimal(StringUtils.toString(map.get("fdExportNum")), fdExportNum));
		setFdfdImportNum(NumberUtils.toBigDecimal(StringUtils.toString(map.get("fdImportNum")), fdImportNum));
		setFdPrice(NumberUtils.toBigDecimal(StringUtils.toString(map.get("fdPrice")), fdPrice));
	}
	
	/**
	 * set the value to Map
	 */
	public Map toMap() {
		
		Map map = new HashMap();
			map.put("fdMaterialCode",StringUtils.toString(fdMaterialCode, eiMetadata.getMeta("fdMaterialCode")));	
			map.put("fdMaterialName",StringUtils.toString(fdMaterialName, eiMetadata.getMeta("fdMaterialName")));		
			map.put("fdSpecModel",StringUtils.toString(fdSpecModel, eiMetadata.getMeta("fdSpecModel")));	
			map.put("fdNumber",StringUtils.toString(fdNumber, eiMetadata.getMeta("fdNumber")));		
			map.put("fdNum",StringUtils.toString(fdNum, eiMetadata.getMeta("fdNum")));	
			map.put("fdExportNum",StringUtils.toString(fdExportNum, eiMetadata.getMeta("fdExportNum")));	
			map.put("fdImportNum",StringUtils.toString(fdImportNum, eiMetadata.getMeta("fdImportNum")));	
			map.put("fdPrice",StringUtils.toString(fdPrice, eiMetadata.getMeta("fdPrice")));	
			
		return map;
	
	}
}